package pers.zyl.product.config;

import org.springframework.cloud.client.loadbalancer.LoadBalanced;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.client.RestTemplate;
import pers.zyl.product.servuce.ProductService;

@Configuration
public class ProductConfig {
    @LoadBalanced
    @Bean
    public RestTemplate restTemplate() {
        return new RestTemplate();
    }

    @Bean
    @GoCondition
    public ProductService productService() {
        return new ProductService();
    }
}
